import 'package:WebTest/chooseFood/core/model/meal_model.dart';
import 'bd_http_request.dart';

class BDHomeMealRequest {
  static Future<List<BDMealModel>> getMealRequestData() async {
    final url = "/meal";
    final result = await HttpRequest.request(url);
    final mealArray = result["meal"];
    List<BDMealModel> meals = [];
    for(var json in mealArray){
      meals.add(BDMealModel.fromJson(json));
    }
    return meals;
  }
}
